package com.xiaoq.shop.entity;

import com.xiaoq.MongoEntity;
import org.hibernate.validator.constraints.NotEmpty;
import org.mongodb.morphia.annotations.Entity;

import javax.validation.constraints.NotNull;

/**
 * Created by qudongxin520 on 2016/11/15.
 */
@Entity(noClassnameStored = true,value = "share_collection")
public class ShareEntity extends MongoEntity {
    private Long shareUserId;
    @NotNull
    @NotEmpty
    private String shareContentId;
    @NotNull
    private Integer type;

    public enum ShareType{
        CORNERSHOP(1), //小店分享标记
        PRODUCT(2);   //商品分享标记
        private int code;
        ShareType(int code){
            this.code = code;
        }
    }

	public Long getShareUserId() {
		return shareUserId;
	}

	public void setShareUserId(Long shareUserId) {
		this.shareUserId = shareUserId;
	}

	public String getShareContentId() {
		return shareContentId;
	}

	public void setShareContentId(String shareContentId) {
		this.shareContentId = shareContentId;
	}

	public Integer getType() {
		return type;
	}

	public void setType(Integer type) {
		this.type = type;
	}
    
    

}
